* ==============================================================================
* ==============================================================================
* Title: Catalyzing aid? The IMF and donor behavior in aid allocation
* Authors: Thomas H. Stubbs, Alexander E. Kentikelenis, Lawrence, P. King
* Version: Final (18 November 2015)
* Contents:
	* Generate variables and macros
	* Table 2. IMF program effect on aid commitments, by sector and total allocation 1995–2009
	* Table 3. Robustness checks, by sector and total aid commitments
	* Table 4. Robustness checks, by bilateral aid commitments
	* Table 5. Robustness checks, by multilateral aid commitments
	* Figure 1. Aid commitments by sector
	* Figure 2. Aid commitments by donor
	* Figure 3. IMF program effect on aid commitments, by bilateral donor
	* Figure 4. IMF selection for aid flows vs. IMF votes, by bilateral donor
	* Figure 5. IMF allocation (OLS fixed effects) for aid flows vs IMF votes, by bilateral donor
	* Figure 6. IMF program effect on aid commitments, by multilateral donor
	* Appendix 1. Descriptive statistics
	* Appendix 2. Base models
	* Appendix 3. Augmented models
	* Appendix 4. Heckman models
	* Appendix 5. System GMM models
	* Appendix 6. Pre-dated models
	* Table R1. IMF program effect on aid commitments, by sector and total (aid flows averaged over three years)
	* Table R2. IMF program effect on aid commitments, by bilateral donor (aid flows averaged over three years)
	* Table R3. IMF program effect on aid commitments, by multilateral donor (aid flows averaged over three years)
	* Figure R1. IMF allocation (system GMM) for aid flows vs IMF votes, by bilateral donor
	* Additional models. Random effects

* ==============================================================================
* Generate variables and macros
* ==============================================================================
cd "D:\Dropbox\Projects\- Completed\IMF Aid Catalysis\"
* Change location to directory where files were unzipped
qui foreach depvar of varlist ac_lntot ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnDACtot ac_lnMLtot ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund ac_lnAUS ac_lnAUT ac_lnBEL ac_lnCAN ac_lnDNK ac_lnFIN ac_lnFRA ac_lnDEU ac_lnGRC ac_lnIRL ac_lnITA ac_lnJPN ac_lnKOR ac_lnLUX ac_lnNLD ac_lnNZL ac_lnNOR ac_lnPRT ac_lnESP ac_lnSWE ac_lnCHE ac_lnGBR ac_lnUSA {
	gen `depvar'D = .
	replace `depvar'D = 1 if `depvar'>0 & !missing(`depvar')
	replace `depvar'D = 0 if `depvar'==0
	egen `depvar'A = filter(`depvar'), l(0/2) n	
}
xtset cid year
qui gen LAGimf_prog = l.imf_prog
local basctrla l.n_lngdppcppp l.m_ggdppcppp l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war
local augctrla l.n_lngdppcppp l.m_ggdppcppp l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war l.n_mortinf l.n_reserves l.n_cab l.n_debtserb l.m_fdi
local basctrlb i.region
local augctrlb i.region s_colony
local basctrlc s_col\`cou' l.s_unga3\`cou' l.s_lntra\`cou'
local augctrlc s_col\`cou' l.s_unga3\`cou' l.s_lntra\`cou' l.s_mil\`cou' s_lang\`cou' s_dist\`cou'
local basctrld l.s_unga3\`cou' l.s_lntra\`cou'
local augctrld l.s_unga3\`cou' l.s_lntra\`cou' l.s_mil\`cou'

* ==============================================================================
* Table 2. IMF program effect on aid commitments, by sector and total allocation 1995–2009
* ==============================================================================
* Sector selection 1995-2009
qui foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: probit `depvar'D LAGimf_prog `basctrla' `basctrlb' i.year if year>=1995 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
eststo clear
* Sector allocation 1995-2009
qui foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: reg `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1995 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
eststo clear
* Total allocation 1986-2009
qui foreach depvar of varlist ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: reg `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
eststo clear

* ==============================================================================
* Table 3. Robustness checks, by sector and total aid commitments
* ==============================================================================
* See Web Appendix & IMFAIDDataFigures.xslx > Table 3

* ==============================================================================
* Table 4. Robustness checks, by bilateral aid commitments
* ==============================================================================
* See Web Appendix & IMFAIDDataFigures.xslx > Table 4

* ==============================================================================
* Table 5. Robustness checks, by multilateral aid commitments
* ==============================================================================
* See Web Appendix & IMFAIDDataFigures.xslx > Table 5

* ==============================================================================
* Figure 1. Aid commitments by sector
* ==============================================================================
preserve
foreach var of varlist ac_tot ac_tot100-ac_tot700 {
	bysort year: egen T`var' = total(`var')
}
gen Tac_rest = Tac_tot - Tac_tot110 - Tac_tot120 - Tac_tot200 - Tac_tot300 - Tac_tot400 - Tac_tot510 - Tac_tot600 - Tac_tot700
lab var Tac_rest "Other Aid"
lab var Tac_tot110 "Education"
lab var Tac_tot120 "Health"
lab var Tac_tot200 "Infrastructure"
lab var Tac_tot300 "Production"
lab var Tac_tot400 "Multisector"
lab var Tac_tot510 "Budget Support"
lab var Tac_tot600 "Debt-Related"
lab var Tac_tot700 "Humanitarian"
graph bar (asis) Tac_tot110  Tac_tot120 Tac_tot200 Tac_tot300 Tac_tot400 Tac_tot510  Tac_tot600  Tac_tot700 Tac_rest if ccode=="CAF" & year>=1986 & year<=2009, over(year, label(angle(45))) yscale(range(0 50000 100000 150000)) ylabel(, angle(90) format(%9.0gc) labsize(small)) stack legend(rows(3) textwidth(30) symxsize(5)) ytitle("2011 USD millions")
graph save "Figures\IMFAIDFigure1.gph", replace
graph export "Figures\IMFAIDFigure1.png", width(2370) height(1725) replace
graph drop _all
restore

* ==============================================================================
* Figure 2. Aid commitments by donor
* ==============================================================================
preserve
foreach var of varlist ac_tot ac_MLtot ac_DACtot ac_AfDF ac_AsDBSpecialFunds ac_IDBSpFund ac_EUInstitutions ac_IDA ac_UNDP ac_UNICEFB  ac_GlobalFund ac_AUS ac_AUT ac_BEL ac_CAN ac_DNK ac_FIN ac_FRA ac_DEU ac_GRC ac_IRL ac_ITA ac_JPN ac_KOR ac_LUX ac_NLD ac_NZL ac_NOR ac_PRT ac_ESP ac_SWE ac_CHE ac_GBR ac_USA {
	bysort year: egen T`var' = total(`var')
}
gen Tac_otherMLtot = Tac_MLtot - Tac_EUInstitutions - Tac_IDA
gen Tac_otherDACtot = Tac_tot - Tac_MLtot - Tac_JPN - Tac_USA
foreach var of varlist Tac_* {
	lab var `var' `"`=substr("`var'",5,.)' `: variable label `var''"'
}
lab var Tac_USA "United States"
lab var Tac_JPN "Japan"
lab var Tac_IDA "World Bank - IDA"
lab var Tac_EUInstitutions "EU Institutions"
lab var Tac_otherMLtot "Other Multilateral"
lab var Tac_otherDACtot "Other Bilateral"
graph bar (asis) Tac_USA Tac_JPN Tac_EUInstitutions Tac_IDA Tac_otherMLtot Tac_otherDACtot if ccode=="CAF" & year>=1986 & year<=2009, over(year, label(angle(45))) yscale(range(0 50000 100000 150000)) ylabel(, angle(90) format(%9.0gc) labsize(small)) stack legend(rows(2) textwidth(30) symxsize(5)) ytitle("2011 USD millions")
graph save "Figures\IMFAIDFigure2.gph", replace
graph export "Figures\IMFAIDFigure2.png", width(2370) height(1725) replace
graph drop _all
restore

* ==============================================================================
* Figure 3. IMF program effect on aid commitments, by bilateral donor
* ==============================================================================
preserve
import excel "IMFAIDDataFigures.xlsx", sheet("FigureBilateralA") firstrow clear
* See Web Appendix for derivation of IMFAIDDataFigures.xslx > FigureBilateralA
gen bilab = 48 - [_n]
replace Selectivityor = Selectivityor + "                    "
twoway (rcap lowerIMFlimit upperIMFlimit bilab if Coefficienttype=="Selection", horizontal scheme(s1color) legend(off) xline(0, lpattern(dash) lcolor(gray)) xlabel(-1.0(0.5)1.0) xtitle("IMF coefficient") ytitle("") ylabel(47 "Australia" 45 "Austria" 43 "Belgium" 41 "Canada" 39 "Denmark" 37 "Finland" 35 "France" 33 "Germany" 31 "Greece" 29 "Ireland" 27 "Italy" 25 "Japan" 23 "Korea" 21 "Luxembourg" 19 "Netherlands" 17 "New Zealand" 15 "Norway" 13 "Portugal" 11 "Spain" 9 "Sweden" 7 "Switzerland" 5 "United Kingdom" 3 "United States", angle(0) grid)) (scatter bilab IMFcoefficient if Coefficienttype=="Selection")(scatter bilab lowerIMFlimit if Coefficienttype=="Selection", mlabel(Selectivityor) mlabposition(0) msymbol(i) mlabcolor(black)), scale(.8) ysize(2) xsize(1) title(Selection) name(g1)
twoway (rcap lowerIMFlimit upperIMFlimit bilab if Coefficienttype=="Allocation", horizontal scheme(s1color) legend(off) xline(0, lpattern(dash) lcolor(gray)) xlabel(-1.0(0.5)1.0) xtitle("IMF coefficient") ytitle("") ylabel(46 "Australia" 44 "Austria" 42 "Belgium" 40 "Canada" 38 "Denmark" 36 "Finland" 34 "France" 32 "Germany" 30 "Greece" 28 "Ireland" 26 "Italy" 24 "Japan" 22 "Korea" 20 "Luxembourg" 18 "Netherlands" 16 "New Zealand" 14 "Norway" 12 "Portugal" 10 "Spain" 8 "Sweden" 6 "Switzerland" 4 "United Kingdom" 2 "United States", angle(0) grid)) (scatter bilab IMFcoefficient if Coefficienttype=="Allocation")(scatter bilab lowerIMFlimit if Coefficienttype=="Allocation", mlabel(Selectivityor) mlabposition(0) msymbol(i) mlabcolor(black)), scale(.8) ysize(2) xsize(1) title(Allocation) name(g2)
graph combine g1 g2,commonscheme
graph save "Figures\IMFAIDFigure3.gph", replace
graph export "Figures\IMFAIDFigure3.png", width(3370) height(2150) replace
graph drop _all
restore

* ==============================================================================
* Figure 4. IMF selection for aid flows vs. IMF votes, by bilateral donor
* ==============================================================================
preserve
import excel "IMFAIDDataFigures.xlsx", sheet("FigureBilateralB") firstrow clear
* See Web Appendix for derivation of IMFAIDDataFigures.xslx > FigureBilateralB
gen Label = Country + SignificantSel
gen IMFSelectionP = IMFSelectionM * 100
lab var IMFSelectionP "Average marginal effect of IMF program on aid selection (%)"
qui: corr IMFSelectionP IMFVotesofFund
local r: display %5.2f r(rho)
twoway (scatter IMFSelectionP IMFVotesofFund if Country!="United States" & Selectivity<0.9, mlabel(Label) mlabsize(small) mlabposition(12) msymbol(o) xtitle("")) (scatter IMFSelectionP IMFVotesofFund if Country!="United States" & Selectivity>0.9, mlabel(Label) mlabsize(small) mlabposition(12) mlabcolor(gray) msymbol(o) xtitle("")), name(gr1, replace) legend(off) ylabel(-10(5)10, angle(0))
scatter IMFSelectionP IMFVotesofFund if Country=="United States", name(gr2, replace) mlabel(Label) mlabsize(small) mlabposition(12) msymbol(o) xlabel(19 " " 18 17 " ", labgap(*3) notick) xtick(18) fxsize(18) yscale(off) xtitle("") ylabel(-10(5)10, angle(0))
graph combine gr1 gr2, cols(2) imargin(small) ycommon b2title("IMF Votes (% of Fund Total)", size(small))
graph save "Figures\IMFAIDFigure4.gph", replace
graph export "Figures\IMFAIDFigure4.png", width(2370) height(1725) replace
graph drop _all
restore

* ==============================================================================
* Figure 5. IMF allocation (OLS fixed effects) for aid flows vs IMF votes, by bilateral donor
* ==============================================================================
preserve
import excel "IMFAIDDataFigures.xlsx", sheet("FigureBilateralB") firstrow clear
* See Web Appendix for derivation of IMFAIDDataFigures.xslx > FigureBilateralB
gen Label = Country + SignificantAll
qui: corr IMFAllocation IMFVotesofFund
local r: display %5.2f r(rho)
gen IMFAllocationP = IMFAllocation * 100
lab var IMFAllocationP "Change in aid allocation due to IMF program (%)"
scatter IMFAllocationP IMFVotesofFund if Country!="United States", name(gr1, replace) mlabel(Label) mlabsize(small) mlabposition(12) msymbol(o) xtitle("") ylabel(-75(25)75, angle(0))
scatter IMFAllocationP IMFVotesofFund if Country=="United States", name(gr2, replace) mlabel(Label) mlabsize(small) mlabposition(12)  msymbol(o) xlabel(19 " " 18 17 " ", labgap(*3) notick) xtick(18) fxsize(18) yscale(off) xtitle("") ylabel(-75(25)75, angle(0))
graph combine gr1 gr2, cols(2) imargin(small) ycommon b2title("IMF Votes (% of Fund Total)", size(small))
graph save "Figures\IMFAIDFigure5.gph", replace
graph export "Figures\IMFAIDFigure5.png", width(2370) height(1725) replace
graph drop _all
restore

* ==============================================================================
* Figure 6. IMF program effect on aid commitments, by multilateral donor
* ==============================================================================
preserve
import excel "IMFAIDDataFigures.xlsx", sheet("FigureMultilateral") firstrow clear
* See Web Appendix for derivation of IMFAIDDataFigures.xslx > FigureBilateralB
gen multilab = 18 - [_n]
replace Selectivityor = Selectivityor + "                    "
twoway (rcap lowerIMFlimit upperIMFlimit multilab if Coefficienttype=="Selection", horizontal scheme(s1color) legend(off) xline(0, lpattern(dash) lcolor(gray)) xlabel(-1.0(0.5)1.5) xtitle("IMF coefficient") ytitle("") ylabel(17 "African Dev. Bank" 15 "Asian Dev. Bank" 13 "Inter-American DB" 11 "EU Institutions" 9 "Int. Dev. Assoc." 7 "UNICEF" 5 "UNDP" 3 "Global Fund", angle(0) grid)) (scatter multilab IMFcoefficient if Coefficienttype=="Selection") (scatter multilab lowerIMFlimit if Coefficienttype=="Selection", mlabel(Selectivityor) mlabposition(0) msymbol(i) mlabcolor(black)), scale(1) ysize(2) xsize(1) title(Selection) name(g1)
twoway (rcap lowerIMFlimit upperIMFlimit multilab if Coefficienttype=="Allocation", horizontal scheme(s1color) legend(off) xline(0, lpattern(dash) lcolor(gray)) xlabel(-1.0(0.5)1.0) xtitle("IMF coefficient") ytitle("") ylabel(16 "African Dev. Bank" 14 "Asian Dev. Bank" 12 "Inter-American DB" 10 "EU Institutions" 8 "Int. Dev. Assoc." 6 "UNICEF" 4 "UNDP" 2 "Global Fund", angle(0) grid)) (scatter multilab IMFcoefficient if Coefficienttype=="Allocation") (scatter multilab lowerIMFlimit if Coefficienttype=="Allocation", mlabel(Selectivityor) mlabposition(0) msymbol(i) mlabcolor(black)), scale(1) ysize(2) xsize(1) title(Allocation) name(g2)
graph combine g1 g2, commonscheme
graph save "Figures\IMFAIDFigure6.gph", replace
graph export "Figures\IMFAIDFigure6.png", width(3370) height(2150) replace
graph drop _all
restore

* ==============================================================================
* Appendix 1. Descriptive statistics
* ==============================================================================
* total aid
qui: reg ac_lntot LAGimf_prog `basctrla' if year>=1986 & year<=2009
summ ac_lnMLtot ac_lnDACtot ac_lntot if e(sample)
* non-dyadic controls
qui: reg ac_lntot LAGimf_prog `basctrla' if year>=1986 & year<=2009
summ LAGimf_prog `basctrla' if e(sample)
* sectoral aid
qui: reg ac_lntot110 `basctrla' if year>=1995 & year<=2009
summ ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 if e(sample)
* bilateral aid and dyadic controls
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU GRC IRL ITA JPN KOR LUX NLD NZL NOR PRT ESP SWE CHE GBR USA {
	qui: reg ac_ln`cou' LAGimf_prog `basctrla' `basctrlc' if year>=1986 & year<=2009
	summ ac_ln`cou' `basctrlc' if e(sample)
}
* multilateral aid
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	qui: reg `depvar' LAGimf_prog `basctrla' if year>=1986 & year<=2009
	summ `depvar' if e(sample)
}

* ==============================================================================
* Appendix 2. Base models
* ==============================================================================
* Table 1. IMF program effect on aid commitments, by sector and total
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: probit `depvar'D LAGimf_prog `basctrla' `basctrlb' i.year if year>=1995 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
		estimates restore `eq'
		margins, dydx(LAGimf_prog)
}
eststo clear
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: reg `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1995 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
foreach depvar of varlist ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: reg `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
* Table 2. IMF program effect on aid commitments, selection, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: probit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: probit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: probit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
* Table 3. IMF program effect on aid commitments, allocation, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: reg ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: reg ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: reg ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
* Table 4. IMF program effect on aid commitments, selection, by multilateral donor
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: probit `depvar'D LAGimf_prog `basctrla' `basctrlb' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
* Table 5. IMF program effect on aid commitments, allocation, by multilateral donor
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: reg `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear

* ==============================================================================
* Appendix 3. Augmented models
* ==============================================================================
* Table 6. IMF program effect on aid commitments, by sector and total
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: probit `depvar'D LAGimf_prog `augctrla' `augctrlb' i.year if year>=1995 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: reg `depvar' LAGimf_prog `augctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
* Table 7. IMF program effect on aid commitments, selection, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: probit ac_ln`cou'D LAGimf_prog `augctrla' `basctrlb' `augctrlc'  i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: probit ac_ln`cou'D LAGimf_prog `augctrla' `basctrlb' `augctrlc' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: probit ac_ln`cou'D LAGimf_prog `augctrla' `basctrlb' `augctrlc' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
* Table 8. IMF program effect on aid commitments, allocation, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: reg ac_ln`cou' LAGimf_prog `augctrla' `augctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: reg ac_ln`cou' LAGimf_prog `augctrla' `augctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: reg ac_ln`cou' LAGimf_prog `augctrla' `augctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear
* Table 9. IMF program effect on aid commitments, selection, by multilateral donor
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: probit `depvar'D LAGimf_prog `augctrla' `augctrlb' i.year if year>=1986 & year<=2009, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) pr2 drop(*year)
esttab, b(3) ci(3) nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
foreach eq of local estno {
	estimates restore `eq'
	margins, dydx(LAGimf_prog)
}
eststo clear
* Table 10. IMF program effect on aid commitments, allocation, by multilateral donor
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: reg `depvar' LAGimf_prog `augctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) r2 drop(*year *cid)
esttab, b(3) ci(3) r2 nostar keep(LAGimf_prog) noobs plain compress
estimates dir
local estno: display r(names)
eststo clear

* ==============================================================================
* Appendix 4. Heckman models
* ==============================================================================
* Table 11. IMF program effect on aid commitments, by sector and total
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: heckman `depvar' LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009, select(`depvar'D = LAGimf_prog `basctrla' `basctrlb' i.year) iter(50) vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(N_cens) sfmt(a2) equations(Main = 1, Selection = 2) order(Selection: Main:) drop(*year *cid)
eststo clear
* Table 12. IMF program effect on aid commitments, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: heckman ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009, select(ac_ln`cou'D = LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year) iter(50) vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(N_cens) sfmt(a2) equations(Main = 1, Selection = 2) order(Selection: Main:) drop(*year *cid)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: heckman ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009, select(ac_ln`cou'D = LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year) iter(50) vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(N_cens) sfmt(a2) equations(Main = 1, Selection = 2) order(Selection: Main:) drop(*year *cid)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: heckman ac_ln`cou' LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009, select(ac_ln`cou'D = LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year) iter(50) vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(N_cens) sfmt(a2) equations(Main = 1, Selection = 2) order(Selection: Main:) drop(*year *cid)
eststo clear
* Table 13. IMF program effect on aid commitments, by multilateral donor
foreach org in AfDF AsDBSpecialFunds IDBSpFund EUInstitutions IDA UNICEFB UNDP GlobalFund {
	eststo: heckman ac_ln`org' LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009, select(ac_ln`org'D = LAGimf_prog `basctrla' `basctrlb' i.year) iter(50) vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(N_cens) sfmt(a2) equations(Main = 1, Selection = 2) order(Selection: Main:) drop(*year *cid)
eststo clear

* ==============================================================================
* Appendix 5. System GMM models
* ==============================================================================
* Table 14. IMF program effect on aid commitments, allocation, by sector and total
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: xtabond2 `depvar' LAGimf_prog `basctrla' l.`depvar' i.year if year>=1986 & year<=2009 & `depvar'D, gmmstyle(l.`depvar' LAGimf_prog l.n_lngdppcppp l.m_ggdppcppp, collapse laglimit(1 .) orthog) ivstyle(l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war i.year) artest(2) orthog twostep robust
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(ar1p ar2p hansenp) drop(*year) sfmt(%9.3f)
eststo clear
* Table 15. IMF program effect on aid commitments, allocation, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: xtabond2 ac_ln`cou' LAGimf_prog `basctrla' `basctrld' l.ac_ln`cou' i.year if year>=1986 & year<=2009 & ac_ln`cou'D, gmmstyle(l.ac_ln`cou' LAGimf_prog l.n_lngdppcppp l.m_ggdppcppp, collapse laglimit(1 .) orthog) ivstyle(l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war l.s_unga3`cou' l.s_lntra`cou' i.year) artest(2) orthog twostep robust
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(ar1p ar2p hansenp) drop(*year) sfmt(%9.3f)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: xtabond2 ac_ln`cou' LAGimf_prog `basctrla' `basctrld' l.ac_ln`cou' i.year if year>=1986 & year<=2009 & ac_ln`cou'D, gmmstyle(l.ac_ln`cou' LAGimf_prog l.n_lngdppcppp l.m_ggdppcppp, collapse laglimit(1 .) orthog) ivstyle(l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war l.s_unga3`cou' l.s_lntra`cou' i.year) artest(2) orthog twostep robust
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(ar1p ar2p hansenp) drop(*year) sfmt(%9.3f)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: xtabond2 ac_ln`cou' LAGimf_prog `basctrla' `basctrld' l.ac_ln`cou' i.year if year>=1986 & year<=2009 & ac_ln`cou'D, gmmstyle(l.ac_ln`cou' LAGimf_prog l.n_lngdppcppp l.m_ggdppcppp, collapse laglimit(1 .) orthog) ivstyle(l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war l.s_unga3`cou' l.s_lntra`cou' i.year) artest(2) orthog twostep robust
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(ar1p ar2p hansenp) drop(*year) sfmt(%9.3f)
eststo clear
* Table 16. IMF program effect on aid commitments, allocation, multilateral donors
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: xtabond2 `depvar' LAGimf_prog `basctrla' l.`depvar' i.year if year>=1986 & year<=2009 & `depvar'D, gmmstyle(l.`depvar' LAGimf_prog l.n_lngdppcppp l.m_ggdppcppp, collapse laglimit(1 .) orthog) ivstyle(l.m_demfhpol l.m_ptss l.s_unsc l.lnpop l.war i.year) artest(2) orthog twostep robust
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) scalars(ar1p ar2p hansenp) drop(*year) sfmt(%9.3f)
eststo clear

* ==============================================================================
* Appendix 6. Pre-dated models
* ==============================================================================
* Table 17. IMF pre-dated program effect on aid commitments, allocation, by sector and total
gen CFimf_prog = l3.imf_prog
gen preexist = (LAGimf_prog==1 & CFimf_prog==1)
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: reg `depvar' CFimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D  & preexist!=1, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
drop CFimf_prog preexist
* Table 18. IMF pre-dated program effect on aid commitments, allocation, by bilateral donor
gen CFimf_prog = l3.imf_prog
gen preexist = (LAGimf_prog==1 & CFimf_prog==1)
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: reg ac_ln`cou' CFimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D & preexist!=1, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: reg ac_ln`cou' CFimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D & preexist!=1, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: reg ac_ln`cou' CFimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D & preexist!=1, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
drop CFimf_prog preexist
* Table 19. IMF pre-dated program effect on aid commitments, allocation, by multilateral donor
gen CFimf_prog = l3.imf_prog
gen preexist = (LAGimf_prog==1 & CFimf_prog==1)
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: reg `depvar' CFimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D & preexist!=1, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
drop CFimf_prog preexist

* ==============================================================================
* Table R1. IMF program effect on aid commitments, by sector and total (aid flows averaged over three years)
* ==============================================================================
* Table included in response to reviewers
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 ac_lnMLtot ac_lnDACtot ac_lntot {
	eststo: reg `depvar'A LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear

* ==============================================================================
* Table R2. IMF program effect on aid commitments, by bilateral donor (aid flows averaged over three years
* ==============================================================================
* Table included in response to reviewers
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: reg ac_ln`cou'A LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: reg ac_ln`cou'A LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: reg ac_ln`cou'A LAGimf_prog `basctrla' `basctrld' i.cid i.year if year>=1986 & year<=2009 & ac_ln`cou'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear

* ==============================================================================
* Table R3. IMF program effect on aid commitments, by multilateral donor (aid flows averaged over three years)
* ==============================================================================
* Table included in response to reviewers
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: reg `depvar'A LAGimf_prog `basctrla' i.cid i.year if year>=1986 & year<=2009 & `depvar'D, vce(cluster cid)
}
esttab, b(3) se(3) nogaps brackets star(* 0.05 ** 0.01) r2 drop(*year *cid)
eststo clear

* ==============================================================================
* Figure R1. IMF allocation (system GMM) for aid flows vs IMF votes, by bilateral donor
* ==============================================================================
* Figure included in response to reviewers
preserve
import excel "IMFAIDDataFigures.xlsx", sheet("FigureBilateralB") firstrow clear
* See Web Appendix for derivation of IMFAIDDataFigures.xslx > FigureBilateralB
gen Label = Country + GMMSignificantAll
qui: corr GMMIMFAllocation IMFVotesofFund
local r: display %5.2f r(rho)
gen GMMIMFAllocationP = GMMIMFAllocation * 100
lab var GMMIMFAllocationP "Change in aid allocation due to IMF program (%)"
scatter GMMIMFAllocationP IMFVotesofFund if Country!="United States", name(gr1, replace) mlabel(Label) mlabsize(small) mlabposition(12) msymbol(o) xtitle("") ylabel(-100(25)100, angle(0))
scatter GMMIMFAllocationP IMFVotesofFund if Country=="United States", name(gr2, replace) mlabel(Label) mlabsize(small) mlabposition(12)  msymbol(o) xlabel(19 " " 18 17 " ", labgap(*3) notick) xtick(18) fxsize(18) yscale(off) xtitle("") ylabel(-100(25)100, angle(0))
graph combine gr1 gr2, cols(2) imargin(small) ycommon b2title("IMF Votes (% of Fund Total)", size(small))
graph save "Figures\IMFAIDFigureR1.gph", replace
graph export "Figures\IMFAIDFigureR1.png", width(2370) height(1725) replace
graph drop _all
restore

* ==============================================================================
* Additional models. Random effects
* ==============================================================================
* Model reported in response to reviewers
* IMF program effect on aid commitments, selection, by sector and total
foreach depvar of varlist ac_lntot110 ac_lntot120 ac_lntot200 ac_lntot300 ac_lntot400 ac_lntot510 ac_lntot600 ac_lntot700 {
	eststo: xtprobit `depvar'D LAGimf_prog `basctrla' `basctrlb' i.year if year>=1995 & year<=2009, re
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) drop(*year)
eststo clear
* IMF program effect on aid commitments, selection, by bilateral donor
foreach cou in AUS AUT BEL CAN DNK FIN FRA DEU {
	eststo: xtprobit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc'  i.year if year>=1986 & year<=2009, re
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) drop(*year)
eststo clear
foreach cou in GRC IRL ITA JPN KOR LUX NLD NZL {
	eststo: xtprobit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year if year>=1986 & year<=2009, re
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) drop(*year)
eststo clear
foreach cou in NOR PRT ESP SWE CHE GBR USA {
	eststo: xtprobit ac_ln`cou'D LAGimf_prog `basctrla' `basctrlb' `basctrlc' i.year if year>=1986 & year<=2009, re
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) drop(*year)
eststo clear
* IMF program effect on aid commitments, selection, by multilateral donor
foreach depvar of varlist ac_lnAfDF ac_lnAsDBSpecialFunds ac_lnIDBSpFund ac_lnEUInstitutions ac_lnIDA ac_lnUNICEFB ac_lnUNDP ac_lnGlobalFund {
	eststo: xtprobit `depvar'D LAGimf_prog `basctrla' `basctrlb' i.year if year>=1986 & year<=2009, re
}
esttab, b(3) se(3) nogaps brackets star(* 0.10 ** 0.05 *** 0.01) drop(*year)
eststo clear

* ==============================================================================
* ==============================================================================